#include "TestContext.hpp"
#include "TestCase.hpp"
#include "TestSecuTradeApi.hpp"
#include "TestTradeSpi.hpp"
#include "TestCaseInterface.hpp"
#include "MyUtils/Thread/ThreadSafeContainer.hpp"

MyUtils::Thread::ThreadSafeQueue<FunctionPtr> g_funcQueue;

namespace TestContext
{
	TestCaseInterface *GetTestCase()
	{
		static TestCase test_case(GetTestTradeSpi());
		return &test_case;
	}
	TestSecuTradeApi *GetTestTradeApi()
	{
		static TestSecuTradeApi test_api;
		return &test_api;
	}

	TestSecuTradeSpi *GetTestTradeSpi()
	{
		static TestSecuTradeSpi test_spi(GetTestTradeApi());
		return &test_spi;
	}

	void Start()
	{
		GetTestTradeSpi()->Start();
	}
}